<?php 
	if(!isset($_SESSION['acms_user']))
	{
		include('./style/pages/403.php'); 
		break;
	}
?>	

<div class="postheader"><h1>Profil</h1></div>
<div class="postcontent">
	<?php
	
	$action1 = change_email();
	$action2 = change_password();
	$action3 = upload();
	
	if(players('image') == "")
	{
		echo "<center><img style='width:75px;height:70px;border: solid 2px #999999;' src='./style/images/unknow.jpg'/></center>";
	}
	else
	{
		$image = players('image');
		echo "<center><img  style='width:75px;height:70px;border: solid 2px #999999;' src='./style/images/avatar/$image'/></center>";
	}
	
	echo "<br />";
	echo "<table>";
	echo "<tr>";
	echo "<td>Pseudo: " . players('pseudo')."</td>";
	echo "</tr>";
	echo "<tr>";
	echo "<td>Email: " . players('email')."</td>";
	echo "</tr>";
	echo "<tr>";
	echo "<td>Rang: " . players('nom')."</td>";
	echo "</tr>";
	echo "</table>";
	echo "<br />";
	
	echo "<table width='100%'>";
	echo "<tr>";
	echo "<td><a href='index.php?page=changeemail' class='button'>Changer d'email</a></td><td><a  href='index.php?page=changepassword' class='button'>Changer de mot de passe</a></td>";
	echo "</tr>";
	echo "</table>";
	
	echo "<br />";
	
	
	echo "<table width='100%'>";
	echo "<tr>";
	echo "<td><a href='index.php?page=avatar' class='button'>Changer d'image</a></td>";
	echo "</tr>";
	echo "</table>";
	
	echo "<center>$action1</center>";
	echo "<center>$action2</center>";
	echo "<center>$action3</center>";
	
?>
</div>